/*
 * Copyright (C) 2009 Christoph Caks
 *
 * This file is part of GLWAK.
 *
 * GLWAK is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * GLWAK is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with GLWAK.  If not, see <http://www.gnu.org/licenses/>.
 *
 *
 * OutputPolicy.cpp
 *
 *  Created on: 20.06.2009
 *      Author: Christoph Caks
 */

#ifndef __OUTPUT_POLICY_CPP_
#define __OUTPUT_POLICY_CPP_

#include "OutputPolicy.h"
#include <cstdio>

namespace glwak {
namespace util {

inline void StdoutOutputPolicy::output( const std::string &msg ) {
	//fprintf( stdout, "%s", msg.c_str() );
	//fflush( stdout );
	std::cout << msg;
}

inline void StderrOutputPolicy::output( const std::string &msg ) {
	//fprintf( stderr, "%s", msg.c_str() );
	//fflush( stderr );
	std::cerr << msg;
}

inline void ConsoleOutputPolicy::output( const std::string &msg ) {
	// TODO somehow bring msg to console
}

} // namespace util
} // namespace glwak

#endif //__OUTPUT_POLICY_CPP_
